package com.tensquare.dto;

/**
 * 响应实体：  springmvc会把这个对象转成String ，String已经实现了序列化接口
 * @author Johnny.Chen
 *
 */
public class Result {
	
	private Integer code;  //响应码
	private Boolean flag;//响应标记
	private String message;//响应信息
	private Object data; //响应数据
	
	
	//四个参数
	public Result(Boolean flag, Integer code, String message, Object data) {
		super();
		this.code = code;
		this.flag = flag;
		this.message = message;
		this.data = data;
	}

	//三个参数
	public Result(Boolean flag, Integer code, String message) {
		super();
		this.code = code;
		this.flag = flag;
		this.message = message;
	}

	//无参
	public Result() {
		super();
	}
	
	
	public Integer getCode() {
		return code;
	}
	public void setCode(Integer code) {
		this.code = code;
	}
	public Boolean getFlag() {
		return flag;
	}
	public void setFlag(Boolean flag) {
		this.flag = flag;
	}
	public String getMessage() {
		return message;
	}
	public void setMessage(String message) {
		this.message = message;
	}
	public Object getData() {
		return data;
	}
	public void setData(Object data) {
		this.data = data;
	}

}
